<script setup>
    import { ref } from 'vue'
    let items = ref(['foo', 'foo123', 'bar', 'bar123'])
    let count = ref(0)
    function increment() {
        count.value++
        items.value = items.value.filter((item) => item.match(/foo/))
    }
</script>

<template>
    <div class="test1">
        <button @click="count++">{{ count }}</button>
        <button @click="increment">{{  count }}</button>
        <span>{{ items }}</span>
    </div>
</template>

<style scoped>
    .test1 button {
        width: 60px;
        height: 30px;
        background-color: aquamarine;
    }
</style>
